<%@ page contentType="text/html; charset=utf-8" language="java" import="java.util.*" pageEncoding="utf-8" errorPage="" %>
<%@ page session="false" %>

<%
	String name = null;
	String creator = null;
	String subject = null;
	
	name = request.getParameter("name");
	creator = request.getParameter("creator");
	subject = request.getParameter("subject");
%>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="pragma" content="no-cache" />
<meta http-equiv="cache-control" content="no-cache" />
<meta http-equiv="Expires" content="0" />
<meta http-equiv="Keywords" content="WebChat,Chat" />
<meta http-equiv="Description" content="Chatting on Web" />
<title>聊天室登录页</title>
<link href="/WebChat/style/global.css" rel="stylesheet" type="text/css" />
<link href="/WebChat/style/chat_lib.css" rel="stylesheet" type="text/css" />

<script type="text/javascript" src="/WebChat/lib/util.js"></script>
<script type="text/javascript">
<!--
	function refreshUserList(){
		openBareWindow('_blank', '/WebChat/servlet/JoinRoomChatServlet?subject=<%= subject %>', 650, 500);
		setTimeout('chat_userlist.location.reload()', 5000);
	}
//-->
</script>

</head>

<body>
<div id="roomcheck">
<%
	if (name != null && creator != null && subject != null) {
%>
  <dl>
    <dt>聊天室名 : </dt>
    <dd><%= name %></dd>
  </dl>
  <dl>
    <dt>聊天室创建者 : </dt>
    <dd><%= creator %></dd>
  </dl>
   <dl>
    <dt>聊天室当前成员 : </dt>
  </dl>
  <div class="list">
    <iframe id="chat_userlist" name="chat_userlist" src="/WebChat/lib/chat_userlist.jsp?subject=<%= subject %>" width="220" height="220" frameborder="0"></iframe>
  </div>
  <div class="button"><a href="#" onclick="refreshUserList();return false">加入</a></div>
<%
	} else {
%>
  <h1>请选择一个聊天室...</h1>
<%
	}
%>
</div>
</body>
</html>